package com.dsp.soundscape.client;

import com.dsp.soundscape.client.services.SoundscapeManagerService;
import com.dsp.soundscape.client.services.SoundscapeManagerServiceAsync;
import com.dsp.soundscape.client.services.ZipService;
import com.dsp.soundscape.client.services.ZipServiceAsync;
import com.google.gwt.core.client.GWT;
import com.google.gwt.user.client.rpc.ServiceDefTarget;


public class ServiceLocator {

	private static SoundscapeManagerServiceAsync soundscapeService = 
		(SoundscapeManagerServiceAsync) GWT.create(SoundscapeManagerService.class);

	private static ZipServiceAsync zipService = 
		(ZipServiceAsync) GWT.create(ZipService.class);

	static {
		((ServiceDefTarget) soundscapeService).setServiceEntryPoint( GWT.getHostPageBaseURL() + "soundscape.rpc");
		((ServiceDefTarget) zipService).setServiceEntryPoint( GWT.getHostPageBaseURL() + "zipper.rpc");
	}
	
	public static SoundscapeManagerServiceAsync getSoundscapeService() {
		return soundscapeService;
	}

	public static ZipServiceAsync getZipService() {
		return zipService;
	}

}
